import pytest
from selenium import webdriver
@pytest.fixture   #默认类中方法级夹具
def get_driver():
    #请打开无头模式
    options = webdriver.EdgeOptions()
    options.add_argument("--headless")
    options.add_argument("--disable-gpu")

    driver = webdriver.Edge(options=options)
    driver.maximize_window()
    yield driver
    driver.quit()


